package Interface;

import java.awt.Color;
import java.awt.Font;
import java.awt.GridLayout;
import java.awt.event.ActionEvent;
import java.awt.event.ActionListener;
import javax.swing.JPanel;
import javax.swing.JTextArea;

public class SouthPanel extends JPanel implements ActionListener
{
    JTextArea statusWindow;
    /*
     * South panel will contain the text area needed to display the game status.
     */
    public SouthPanel()
    {
        //set parameters of south panel
        setSize(300, 768);
        setLayout(new GridLayout(1,1));
        add(getStatusWindow());
    }

    private JTextArea getStatusWindow()
    {
        statusWindow = new JTextArea();
        statusWindow.setSize(200, 768);
        statusWindow.setEditable(false);
        statusWindow.setFont(new Font("Serif", 0, 12));
        statusWindow.setText("bacon \n\n\n\n\n\n\n\n\n\n\n");
        statusWindow.setBackground(Color.black);
        statusWindow.setForeground(Color.white);
        
        return statusWindow;
    }

    public void writeToStatusWindow(String text)
    {
        statusWindow.append(text + "\n");
    }

    public void actionPerformed(ActionEvent e) {
        throw new UnsupportedOperationException("Not supported yet.");
    }


}